home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 13 / CU Amiga Magazine's Super CD-ROM 13 (1997)(EMAP Images)(GB)(Track 1 of 2)[!][issue 1997-08].iso / CUCD / Graphics / Ghostscript / src / jpeg-6a / configure < prev    next >
Text File  |  1996-02-07  |  49KB  |  1,732 lines

  1. #! /bin/sh
  2.  
  3. # Guess values for system-dependent variables and create Makefiles.
  4. # Generated automatically using autoconf version 2.7 
  5. # Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
  6. #
  7. # This configure script is free software; the Free Software Foundation
  8. # gives unlimited permission to copy, distribute and modify it.
  9.  
  10. # Defaults:
  11. ac_help=
  12. ac_default_prefix=/usr/local
  13. # Any additions from configure.in:
  14. ac_help="$ac_help
  15.   --enable-maxmem[=N]     enable use of temp files, set max mem usage to N MB"
  16. ac_help="$ac_help
  17. "
  18.  
  19. # Initialize some variables set by options.
  20. # The variables have the same names as the options, with
  21. # dashes changed to underlines.
  22. build=NONE
  23. cache_file=./config.cache
  24. exec_prefix=NONE
  25. host=NONE
  26. no_create=
  27. nonopt=NONE
  28. no_recursion=
  29. prefix=NONE
  30. program_prefix=NONE
  31. program_suffix=NONE
  32. program_transform_name=s,x,x,
  33. silent=
  34. site=
  35. srcdir=
  36. target=NONE
  37. verbose=
  38. x_includes=NONE
  39. x_libraries=NONE
  40. bindir='${exec_prefix}/bin'
  41. sbindir='${exec_prefix}/sbin'
  42. libexecdir='${exec_prefix}/libexec'
  43. datadir='${prefix}/share'
  44. sysconfdir='${prefix}/etc'
  45. sharedstatedir='${prefix}/com'
  46. localstatedir='${prefix}/var'
  47. libdir='${exec_prefix}/lib'
  48. includedir='${prefix}/include'
  49. oldincludedir='/usr/include'
  50. infodir='${prefix}/info'
  51. mandir='${prefix}/man'
  52.  
  53. # Initialize some other variables.
  54. subdirs=
  55. MFLAGS= MAKEFLAGS=
  56.  
  57. ac_prev=
  58. for ac_option
  59. do
  60.  
  61.   # If the previous option needs an argument, assign it.
  62.   if test -n "$ac_prev"; then
  63.     eval "$ac_prev=\$ac_option"
  64.     ac_prev=
  65.     continue
  66.   fi
  67.  
  68.   case "$ac_option" in
  69.   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  70.   *) ac_optarg= ;;
  71.   esac
  72.  
  73.   # Accept the important Cygnus configure options, so we can diagnose typos.
  74.  
  75.   case "$ac_option" in
  76.  
  77.   -bindir | --bindir | --bindi | --bind | --bin | --bi)
  78.     ac_prev=bindir ;;
  79.   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
  80.     bindir="$ac_optarg" ;;
  81.  
  82.   -build | --build | --buil | --bui | --bu)
  83.     ac_prev=build ;;
  84.   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
  85.     build="$ac_optarg" ;;
  86.  
  87.   -cache-file | --cache-file | --cache-fil | --cache-fi \
  88.   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  89.     ac_prev=cache_file ;;
  90.   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  91.   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  92.     cache_file="$ac_optarg" ;;
  93.  
  94.   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
  95.     ac_prev=datadir ;;
  96.   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
  97.   | --da=*)
  98.     datadir="$ac_optarg" ;;
  99.  
  100.   -disable-* | --disable-*)
  101.     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
  102.     # Reject names that are not valid shell variable names.
  103.     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
  104.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  105.     fi
  106.     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  107.     eval "enable_${ac_feature}=no" ;;
  108.  
  109.   -enable-* | --enable-*)
  110.     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
  111.     # Reject names that are not valid shell variable names.
  112.     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
  113.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  114.     fi
  115.     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  116.     case "$ac_option" in
  117.       *=*) ;;
  118.       *) ac_optarg=yes ;;
  119.     esac
  120.     eval "enable_${ac_feature}='$ac_optarg'" ;;
  121.  
  122.   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  123.   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  124.   | --exec | --exe | --ex)
  125.     ac_prev=exec_prefix ;;
  126.   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  127.   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  128.   | --exec=* | --exe=* | --ex=*)
  129.     exec_prefix="$ac_optarg" ;;
  130.  
  131.   -gas | --gas | --ga | --g)
  132.     # Obsolete; use --with-gas.
  133.     with_gas=yes ;;
  134.  
  135.   -help | --help | --hel | --he)
  136.     # Omit some internal or obsolete options to make the list less imposing.
  137.     # This message is too long to be a string in the A/UX 3.1 sh.
  138.     cat << EOF
  139. Usage: configure [options] [host]
  140. Options: [defaults in brackets after descriptions]
  141. Configuration:
  142.   --cache-file=FILE       cache test results in FILE
  143.   --help                  print this message
  144.   --no-create             do not create output files
  145.   --quiet, --silent       do not print \`checking...' messages
  146.   --version               print the version of autoconf that created configure
  147. Directory and file names:
  148.   --prefix=PREFIX         install architecture-independent files in PREFIX
  149.                           [$ac_default_prefix]
  150.   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
  151.                           [same as prefix]
  152.   --bindir=DIR            user executables in DIR [EPREFIX/bin]
  153.   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
  154.   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
  155.   --datadir=DIR           read-only architecture-independent data in DIR
  156.                           [PREFIX/share]
  157.   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
  158.   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
  159.                           [PREFIX/com]
  160.   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
  161.   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
  162.   --includedir=DIR        C header files in DIR [PREFIX/include]
  163.   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
  164.   --infodir=DIR           info documentation in DIR [PREFIX/info]
  165.   --mandir=DIR            man documentation in DIR [PREFIX/man]
  166.   --srcdir=DIR            find the sources in DIR [configure dir or ..]
  167.   --program-prefix=PREFIX prepend PREFIX to installed program names
  168.   --program-suffix=SUFFIX append SUFFIX to installed program names
  169.   --program-transform-name=PROGRAM
  170.                           run sed PROGRAM on installed program names
  171. EOF
  172.     cat << EOF
  173. Host type:
  174.   --build=BUILD           configure for building on BUILD [BUILD=HOST]
  175.   --host=HOST             configure for HOST [guessed]
  176.   --target=TARGET         configure for TARGET [TARGET=HOST]
  177. Features and packages:
  178.   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  179.   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  180.   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  181.   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  182.   --x-includes=DIR        X include files are in DIR
  183.   --x-libraries=DIR       X library files are in DIR
  184. EOF
  185.     if test -n "$ac_help"; then
  186.       echo "--enable and --with options recognized:$ac_help"
  187.     fi
  188.     exit 0 ;;
  189.  
  190.   -host | --host | --hos | --ho)
  191.     ac_prev=host ;;
  192.   -host=* | --host=* | --hos=* | --ho=*)
  193.     host="$ac_optarg" ;;
  194.  
  195.   -includedir | --includedir | --includedi | --included | --include \
  196.   | --includ | --inclu | --incl | --inc)
  197.     ac_prev=includedir ;;
  198.   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  199.   | --includ=* | --inclu=* | --incl=* | --inc=*)
  200.     includedir="$ac_optarg" ;;
  201.  
  202.   -infodir | --infodir | --infodi | --infod | --info | --inf)
  203.     ac_prev=infodir ;;
  204.   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
  205.     infodir="$ac_optarg" ;;
  206.  
  207.   -libdir | --libdir | --libdi | --libd)
  208.     ac_prev=libdir ;;
  209.   -libdir=* | --libdir=* | --libdi=* | --libd=*)
  210.     libdir="$ac_optarg" ;;
  211.  
  212.   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  213.   | --libexe | --libex | --libe)
  214.     ac_prev=libexecdir ;;
  215.   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  216.   | --libexe=* | --libex=* | --libe=*)
  217.     libexecdir="$ac_optarg" ;;
  218.  
  219.   -localstatedir | --localstatedir | --localstatedi | --localstated \
  220.   | --localstate | --localstat | --localsta | --localst \
  221.   | --locals | --local | --loca | --loc | --lo)
  222.     ac_prev=localstatedir ;;
  223.   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  224.   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
  225.   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
  226.     localstatedir="$ac_optarg" ;;
  227.  
  228.   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
  229.     ac_prev=mandir ;;
  230.   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
  231.     mandir="$ac_optarg" ;;
  232.  
  233.   -nfp | --nfp | --nf)
  234.     # Obsolete; use --without-fp.
  235.     with_fp=no ;;
  236.  
  237.   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  238.   | --no-cr | --no-c)
  239.     no_create=yes ;;
  240.  
  241.   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  242.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
  243.     no_recursion=yes ;;
  244.  
  245.   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  246.   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  247.   | --oldin | --oldi | --old | --ol | --o)
  248.     ac_prev=oldincludedir ;;
  249.   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  250.   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  251.   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
  252.     oldincludedir="$ac_optarg" ;;
  253.  
  254.   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  255.     ac_prev=prefix ;;
  256.   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  257.     prefix="$ac_optarg" ;;
  258.  
  259.   -program-prefix | --program-prefix | --program-prefi | --program-pref \
  260.   | --program-pre | --program-pr | --program-p)
  261.     ac_prev=program_prefix ;;
  262.   -program-prefix=* | --program-prefix=* | --program-prefi=* \
  263.   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  264.     program_prefix="$ac_optarg" ;;
  265.  
  266.   -program-suffix | --program-suffix | --program-suffi | --program-suff \
  267.   | --program-suf | --program-su | --program-s)
  268.     ac_prev=program_suffix ;;
  269.   -program-suffix=* | --program-suffix=* | --program-suffi=* \
  270.   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  271.     program_suffix="$ac_optarg" ;;
  272.  
  273.   -program-transform-name | --program-transform-name \
  274.   | --program-transform-nam | --program-transform-na \
  275.   | --program-transform-n | --program-transform- \
  276.   | --program-transform | --program-transfor \
  277.   | --program-transfo | --program-transf \
  278.   | --program-trans | --program-tran \
  279.   | --progr-tra | --program-tr | --program-t)
  280.     ac_prev=program_transform_name ;;
  281.   -program-transform-name=* | --program-transform-name=* \
  282.   | --program-transform-nam=* | --program-transform-na=* \
  283.   | --program-transform-n=* | --program-transform-=* \
  284.   | --program-transform=* | --program-transfor=* \
  285.   | --program-transfo=* | --program-transf=* \
  286.   | --program-trans=* | --program-tran=* \
  287.   | --progr-tra=* | --program-tr=* | --program-t=*)
  288.     program_transform_name="$ac_optarg" ;;
  289.  
  290.   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  291.   | -silent | --silent | --silen | --sile | --sil)
  292.     silent=yes ;;
  293.  
  294.   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
  295.     ac_prev=sbindir ;;
  296.   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  297.   | --sbi=* | --sb=*)
  298.     sbindir="$ac_optarg" ;;
  299.  
  300.   -sharedstatedir | --sharedstatedir | --sharedstatedi \
  301.   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  302.   | --sharedst | --shareds | --shared | --share | --shar \
  303.   | --sha | --sh)
  304.     ac_prev=sharedstatedir ;;
  305.   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  306.   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  307.   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  308.   | --sha=* | --sh=*)
  309.     sharedstatedir="$ac_optarg" ;;
  310.  
  311.   -site | --site | --sit)
  312.     ac_prev=site ;;
  313.   -site=* | --site=* | --sit=*)
  314.     site="$ac_optarg" ;;
  315.  
  316.   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  317.     ac_prev=srcdir ;;
  318.   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  319.     srcdir="$ac_optarg" ;;
  320.  
  321.   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  322.   | --syscon | --sysco | --sysc | --sys | --sy)
  323.     ac_prev=sysconfdir ;;
  324.   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  325.   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
  326.     sysconfdir="$ac_optarg" ;;
  327.  
  328.   -target | --target | --targe | --targ | --tar | --ta | --t)
  329.     ac_prev=target ;;
  330.   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  331.     target="$ac_optarg" ;;
  332.  
  333.   -v | -verbose | --verbose | --verbos | --verbo | --verb)
  334.     verbose=yes ;;
  335.  
  336.   -version | --version | --versio | --versi | --vers)
  337.     echo "configure generated by autoconf version 2.7"
  338.     exit 0 ;;
  339.  
  340.   -with-* | --with-*)
  341.     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
  342.     # Reject names that are not valid shell variable names.
  343.     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
  344.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  345.     fi
  346.     ac_package=`echo $ac_package| sed 's/-/_/g'`
  347.     case "$ac_option" in
  348.       *=*) ;;
  349.       *) ac_optarg=yes ;;
  350.     esac
  351.     eval "with_${ac_package}='$ac_optarg'" ;;
  352.  
  353.   -without-* | --without-*)
  354.     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
  355.     # Reject names that are not valid shell variable names.
  356.     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
  357.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  358.     fi
  359.     ac_package=`echo $ac_package| sed 's/-/_/g'`
  360.     eval "with_${ac_package}=no" ;;
  361.  
  362.   --x)
  363.     # Obsolete; use --with-x.
  364.     with_x=yes ;;
  365.  
  366.   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  367.   | --x-incl | --x-inc | --x-in | --x-i)
  368.     ac_prev=x_includes ;;
  369.   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  370.   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  371.     x_includes="$ac_optarg" ;;
  372.  
  373.   -x-libraries | --x-libraries | --x-librarie | --x-librari \
  374.   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  375.     ac_prev=x_libraries ;;
  376.   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  377.   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  378.     x_libraries="$ac_optarg" ;;
  379.  
  380.   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
  381.     ;;
  382.  
  383.   *=*)
  384.     varname=`echo "$ac_option"|sed -e 's/=.*//'`
  385.     # Reject names that aren't valid shell variable names.
  386.     if test -n "`echo $varname| sed 's/[a-zA-Z0-9_]//g'`"; then
  387.       { echo "configure: error: $varname: invalid shell variable name" 1>&2; exit 1; }
  388.     fi
  389.     val="`echo "$ac_option"|sed 's/[^=]*=//'`"
  390.     test -n "$verbose" && echo "    setting shell variable $varname to $val"
  391.     eval "$varname='$val'"
  392.     eval "export $varname" ;;
  393.  
  394.   *)
  395.     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
  396.       echo "configure: warning: $ac_option: invalid host type" 1>&2
  397.     fi
  398.     if test "x$nonopt" != xNONE; then
  399.       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
  400.     fi
  401.     nonopt="$ac_option"
  402.     ;;
  403.  
  404.   esac
  405. done
  406.  
  407. if test -n "$ac_prev"; then
  408.   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
  409. fi
  410.  
  411. trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
  412.  
  413. # File descriptor usage:
  414. # 0 standard input
  415. # 1 file creation
  416. # 2 errors and warnings
  417. # 3 some systems may open it to /dev/tty
  418. # 4 used on the Kubota Titan
  419. # 6 checking for... messages and results
  420. # 5 compiler messages saved in config.log
  421. if test "$silent" = yes; then
  422.   exec 6>/dev/null
  423. else
  424.   exec 6>&1
  425. fi
  426. exec 5>./config.log
  427.  
  428. echo "\
  429. This file contains any messages produced by compilers while
  430. running configure, to aid debugging if configure makes a mistake.
  431. " 1>&5
  432.  
  433. # Strip out --no-create and --no-recursion so they do not pile up.
  434. # Also quote any args containing shell metacharacters.
  435. ac_configure_args=
  436. for ac_arg
  437. do
  438.   case "$ac_arg" in
  439.   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  440.   | --no-cr | --no-c) ;;
  441.   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  442.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  443.   *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
  444.   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
  445.   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
  446.   esac
  447. done
  448.  
  449. # NLS nuisances.
  450. # Only set LANG and LC_ALL to C if already set.
  451. # These must not be set unconditionally because not all systems understand
  452. # e.g. LANG=C (notably SCO).
  453. if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
  454. if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
  455.  
  456. # confdefs.h avoids OS command line length limits that DEFS can exceed.
  457. rm -rf conftest* confdefs.h
  458. # AIX cpp loses on an empty file, so make sure it contains at least a newline.
  459. echo > confdefs.h
  460.  
  461. # A filename unique to this package, relative to the directory that
  462. # configure is in, which we can look for to find out if srcdir is correct.
  463. ac_unique_file=jcmaster.c
  464.  
  465. # Find the source files, if location was not specified.
  466. if test -z "$srcdir"; then
  467.   ac_srcdir_defaulted=yes
  468.   # Try the directory containing this script, then its parent.
  469.   ac_prog=$0
  470.   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  471.   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
  472.   srcdir=$ac_confdir
  473.   if test ! -r $srcdir/$ac_unique_file; then
  474.     srcdir=..
  475.   fi
  476. else
  477.   ac_srcdir_defaulted=no
  478. fi
  479. if test ! -r $srcdir/$ac_unique_file; then
  480.   if test "$ac_srcdir_defaulted" = yes; then
  481.     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
  482.   else
  483.     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
  484.   fi
  485. fi
  486. srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
  487.  
  488. # Prefer explicitly selected file to automatically selected ones.
  489. if test -z "$CONFIG_SITE"; then
  490.   if test "x$prefix" != xNONE; then
  491.     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
  492.   else
  493.     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
  494.   fi
  495. fi
  496. for ac_site_file in $CONFIG_SITE; do
  497.   if test -r "$ac_site_file"; then
  498.     echo "loading site script $ac_site_file"
  499.     . "$ac_site_file"
  500.   fi
  501. done
  502.  
  503.  
  504. ac_ext=c
  505. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  506. ac_cpp='echo $CPP $CPPFLAGS 1>&5;
  507. $CPP $CPPFLAGS'
  508. ac_compile='echo ${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5;
  509. ${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5 2>&5'
  510. ac_link='echo ${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5;
  511. ${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5 2>&5'
  512.  
  513. if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
  514.   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
  515.   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
  516.     ac_n= ac_c='
  517. ' ac_t='    '
  518.   else
  519.     ac_n=-n ac_c= ac_t=
  520.   fi
  521. else
  522.   ac_n= ac_c='\c' ac_t=
  523. fi
  524.  
  525.  
  526.  
  527. # Extract the first word of "gcc", so it can be a program name with args.
  528. set dummy gcc; ac_word=$2
  529. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  530. if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
  531.   echo $ac_n "(cached) $ac_c" 1>&6
  532. else
  533.   if test -n "$CC"; then
  534.   ac_cv_prog_CC="$CC" # Let the user override the test.
  535. else
  536.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  537.   for ac_dir in $PATH; do
  538.     test -z "$ac_dir" && ac_dir=.
  539.     if test -f $ac_dir/$ac_word; then
  540.       ac_cv_prog_CC="gcc"
  541.       break
  542.     fi
  543.   done
  544.   IFS="$ac_save_ifs"
  545.   test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc"
  546. fi
  547. fi
  548. CC="$ac_cv_prog_CC"
  549. if test -n "$CC"; then
  550.   echo "$ac_t""$CC" 1>&6
  551. else
  552.   echo "$ac_t""no" 1>&6
  553. fi
  554.  
  555.  
  556. echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
  557. if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
  558.   echo $ac_n "(cached) $ac_c" 1>&6
  559. else
  560.   cat > conftest.c <<EOF
  561. #ifdef __GNUC__
  562.   yes;
  563. #endif
  564. EOF
  565. if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then
  566.   ac_cv_prog_gcc=yes
  567. else
  568.   ac_cv_prog_gcc=no
  569. fi
  570. fi
  571. echo "$ac_t""$ac_cv_prog_gcc" 1>&6
  572. if test $ac_cv_prog_gcc = yes; then
  573.   GCC=yes
  574. else
  575.   GCC=
  576. fi
  577. if test "${CFLAGS+set}" != set; then
  578.   echo $ac_n "checking whether ${CC-cc} accepts -O""... $ac_c" 1>&6
  579. if eval "test \"`echo '$''{'ac_cv_prog_cc_o'+set}'`\" = set"; then
  580.   echo $ac_n "(cached) $ac_c" 1>&6
  581. else
  582.   echo 'int f(){ return 0; }' > conftest.c
  583. if test -z "`${CC-cc} -O -c conftest.c 2>&1`"; then
  584.   ac_cv_prog_cc_o=yes
  585. else
  586.   ac_cv_prog_cc_o=no
  587. fi
  588. rm -f conftest*
  589.  
  590. fi
  591.   echo "$ac_t""$ac_cv_prog_cc_o" 1>&6
  592.   if test $ac_cv_prog_cc_o = yes; then
  593.     CFLAGS="-O"
  594.   else
  595.     CFLAGS=""
  596.   fi
  597. fi
  598.  
  599. echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
  600. # On Suns, sometimes $CPP names a directory.
  601. if test -n "$CPP" && test -d "$CPP"; then
  602.   CPP=
  603. fi
  604. if test -z "$CPP"; then
  605. if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
  606.   echo $ac_n "(cached) $ac_c" 1>&6
  607. else
  608.     # This must be in double quotes, not single quotes, because CPP may get
  609.   # substituted into the Makefile and "${CC-cc}" will confuse make.
  610.   CPP="${CC-cc} -E"
  611.   # On the NeXT, cc -E runs the code through the compiler's parser,
  612.   # not just through cpp.
  613.   cat > conftest.$ac_ext <<EOF
  614. #line 615 "configure"
  615. #include "confdefs.h"
  616. #include <assert.h>
  617. Syntax Error
  618. EOF
  619. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  620. ac_err=`grep -v '^ *+' conftest.out`
  621. if test -z "$ac_err"; then
  622.   :
  623. else
  624.   echo "$ac_err" >&5
  625.   rm -rf conftest*
  626.   CPP="${CC-cc} -E -traditional-cpp"
  627.   cat > conftest.$ac_ext <<EOF
  628. #line 629 "configure"
  629. #include "confdefs.h"
  630. #include <assert.h>
  631. Syntax Error
  632. EOF
  633. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  634. ac_err=`grep -v '^ *+' conftest.out`
  635. if test -z "$ac_err"; then
  636.   :
  637. else
  638.   echo "$ac_err" >&5
  639.   rm -rf conftest*
  640.   CPP=/lib/cpp
  641. fi
  642. rm -f conftest*
  643. fi
  644. rm -f conftest*
  645.   ac_cv_prog_CPP="$CPP"
  646. fi
  647.   CPP="$ac_cv_prog_CPP"
  648. else
  649.   ac_cv_prog_CPP="$CPP"
  650. fi
  651. echo "$ac_t""$CPP" 1>&6
  652.  
  653. # If we cannot run a trivial program, we must be cross compiling.
  654. echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&6
  655. if eval "test \"`echo '$''{'ac_cv_c_cross'+set}'`\" = set"; then
  656.   echo $ac_n "(cached) $ac_c" 1>&6
  657. else
  658.   if test "$cross_compiling" = yes; then
  659.   ac_cv_c_cross=yes
  660. else
  661. cat > conftest.$ac_ext <<EOF
  662. #line 663 "configure"
  663. #include "confdefs.h"
  664. main(){return(0);}
  665. EOF
  666. eval $ac_link
  667. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  668.   ac_cv_c_cross=no
  669. else
  670.   ac_cv_c_cross=yes
  671. fi
  672. fi
  673. rm -fr conftest*
  674. fi
  675.  
  676. echo "$ac_t""$ac_cv_c_cross" 1>&6
  677. cross_compiling=$ac_cv_c_cross
  678.  
  679. echo $ac_n "checking for function prototypes""... $ac_c" 1>&6
  680. if eval "test \"`echo '$''{'ijg_cv_have_prototypes'+set}'`\" = set"; then
  681.   echo $ac_n "(cached) $ac_c" 1>&6
  682. else
  683.   cat > conftest.$ac_ext <<EOF
  684. #line 685 "configure"
  685. #include "confdefs.h"
  686.  
  687. int testfunction (int arg1, int * arg2); /* check prototypes */
  688. struct methods_struct {        /* check method-pointer declarations */
  689.   int (*error_exit) (char *msgtext);
  690.   int (*trace_message) (char *msgtext);
  691.   int (*another_method) (void);
  692. };
  693. int testfunction (int arg1, int * arg2) /* check definitions */
  694. { return arg2[arg1]; }
  695. int test2function (void)    /* check void arg list */
  696. { return 0; }
  697.  
  698. int main() { return 0; }
  699. int t() {
  700.  
  701. ; return 0; }
  702. EOF
  703. if eval $ac_compile; then
  704.   rm -rf conftest*
  705.   ijg_cv_have_prototypes=yes
  706. else
  707.   rm -rf conftest*
  708.   ijg_cv_have_prototypes=no
  709. fi
  710. rm -f conftest*
  711.  
  712. fi
  713. echo "$ac_t""$ijg_cv_have_prototypes" 1>&6
  714. if test $ijg_cv_have_prototypes = yes; then
  715.   cat >> confdefs.h <<\EOF
  716. #define HAVE_PROTOTYPES 
  717. EOF
  718.  
  719. else
  720.   echo Your compiler does not seem to know about function prototypes.
  721.   echo Perhaps it needs a special switch to enable ANSI C mode.
  722.   echo If so, we recommend running configure like this:
  723.   echo "   ./configure  CC='cc -switch'"
  724.   echo where -switch is the proper switch.
  725. fi
  726. ac_safe=`echo "stddef.h" | tr './\055' '___'`
  727. echo $ac_n "checking for stddef.h""... $ac_c" 1>&6
  728. if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  729.   echo $ac_n "(cached) $ac_c" 1>&6
  730. else
  731.   cat > conftest.$ac_ext <<EOF
  732. #line 733 "configure"
  733. #include "confdefs.h"
  734. #include <stddef.h>
  735. EOF
  736. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  737. ac_err=`grep -v '^ *+' conftest.out`
  738. if test -z "$ac_err"; then
  739.   rm -rf conftest*
  740.   eval "ac_cv_header_$ac_safe=yes"
  741. else
  742.   echo "$ac_err" >&5
  743.   rm -rf conftest*
  744.   eval "ac_cv_header_$ac_safe=no"
  745. fi
  746. rm -f conftest*
  747. fi
  748. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  749.   echo "$ac_t""yes" 1>&6
  750.   cat >> confdefs.h <<\EOF
  751. #define HAVE_STDDEF_H 
  752. EOF
  753.  
  754. else
  755.   echo "$ac_t""no" 1>&6
  756. fi
  757.  
  758. ac_safe=`echo "stdlib.h" | tr './\055' '___'`
  759. echo $ac_n "checking for stdlib.h""... $ac_c" 1>&6
  760. if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  761.   echo $ac_n "(cached) $ac_c" 1>&6
  762. else
  763.   cat > conftest.$ac_ext <<EOF
  764. #line 765 "configure"
  765. #include "confdefs.h"
  766. #include <stdlib.h>
  767. EOF
  768. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  769. ac_err=`grep -v '^ *+' conftest.out`
  770. if test -z "$ac_err"; then
  771.   rm -rf conftest*
  772.   eval "ac_cv_header_$ac_safe=yes"
  773. else
  774.   echo "$ac_err" >&5
  775.   rm -rf conftest*
  776.   eval "ac_cv_header_$ac_safe=no"
  777. fi
  778. rm -f conftest*
  779. fi
  780. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  781.   echo "$ac_t""yes" 1>&6
  782.   cat >> confdefs.h <<\EOF
  783. #define HAVE_STDLIB_H 
  784. EOF
  785.  
  786. else
  787.   echo "$ac_t""no" 1>&6
  788. fi
  789.  
  790. ac_safe=`echo "string.h" | tr './\055' '___'`
  791. echo $ac_n "checking for string.h""... $ac_c" 1>&6
  792. if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  793.   echo $ac_n "(cached) $ac_c" 1>&6
  794. else
  795.   cat > conftest.$ac_ext <<EOF
  796. #line 797 "configure"
  797. #include "confdefs.h"
  798. #include <string.h>
  799. EOF
  800. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  801. ac_err=`grep -v '^ *+' conftest.out`
  802. if test -z "$ac_err"; then
  803.   rm -rf conftest*
  804.   eval "ac_cv_header_$ac_safe=yes"
  805. else
  806.   echo "$ac_err" >&5
  807.   rm -rf conftest*
  808.   eval "ac_cv_header_$ac_safe=no"
  809. fi
  810. rm -f conftest*
  811. fi
  812. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  813.   echo "$ac_t""yes" 1>&6
  814.   :
  815. else
  816.   echo "$ac_t""no" 1>&6
  817. cat >> confdefs.h <<\EOF
  818. #define NEED_BSD_STRINGS 
  819. EOF
  820.  
  821. fi
  822.  
  823. echo $ac_n "checking for size_t""... $ac_c" 1>&6
  824. cat > conftest.$ac_ext <<EOF
  825. #line 826 "configure"
  826. #include "confdefs.h"
  827.  
  828. #ifdef HAVE_STDDEF_H
  829. #include <stddef.h>
  830. #endif
  831. #ifdef HAVE_STDLIB_H
  832. #include <stdlib.h>
  833. #endif
  834. #include <stdio.h>
  835. #ifdef NEED_BSD_STRINGS
  836. #include <strings.h>
  837. #else
  838. #include <string.h>
  839. #endif
  840. typedef size_t my_size_t;
  841.  
  842. int main() { return 0; }
  843. int t() {
  844.  my_size_t foovar; 
  845. ; return 0; }
  846. EOF
  847. if eval $ac_compile; then
  848.   rm -rf conftest*
  849.   ijg_size_t_ok=yes
  850. else
  851.   rm -rf conftest*
  852.   ijg_size_t_ok="not ANSI, perhaps it is in sys/types.h"
  853. fi
  854. rm -f conftest*
  855.  
  856. echo "$ac_t""$ijg_size_t_ok" 1>&6
  857. if test "$ijg_size_t_ok" != yes; then
  858. ac_safe=`echo "sys/types.h" | tr './\055' '___'`
  859. echo $ac_n "checking for sys/types.h""... $ac_c" 1>&6
  860. if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  861.   echo $ac_n "(cached) $ac_c" 1>&6
  862. else
  863.   cat > conftest.$ac_ext <<EOF
  864. #line 865 "configure"
  865. #include "confdefs.h"
  866. #include <sys/types.h>
  867. EOF
  868. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  869. ac_err=`grep -v '^ *+' conftest.out`
  870. if test -z "$ac_err"; then
  871.   rm -rf conftest*
  872.   eval "ac_cv_header_$ac_safe=yes"
  873. else
  874.   echo "$ac_err" >&5
  875.   rm -rf conftest*
  876.   eval "ac_cv_header_$ac_safe=no"
  877. fi
  878. rm -f conftest*
  879. fi
  880. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  881.   echo "$ac_t""yes" 1>&6
  882.   cat >> confdefs.h <<\EOF
  883. #define NEED_SYS_TYPES_H 
  884. EOF
  885.  
  886. cat > conftest.$ac_ext <<EOF
  887. #line 888 "configure"
  888. #include "confdefs.h"
  889. #include <sys/types.h>
  890. EOF
  891. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  892.   egrep "size_t" >/dev/null 2>&1; then
  893.   rm -rf conftest*
  894.   ijg_size_t_ok="size_t is in sys/types.h"
  895. else
  896.   rm -rf conftest*
  897.   ijg_size_t_ok=no
  898. fi
  899. rm -f conftest*
  900.  
  901. else
  902.   echo "$ac_t""no" 1>&6
  903. ijg_size_t_ok=no
  904. fi
  905.  
  906. echo "$ac_t""$ijg_size_t_ok" 1>&6
  907. if test "$ijg_size_t_ok" = no; then
  908.   echo Type size_t is not defined in any of the usual places.
  909.   echo Try putting '"typedef unsigned int size_t;"' in jconfig.h.
  910. fi
  911. fi
  912. echo $ac_n "checking for type unsigned char""... $ac_c" 1>&6
  913. cat > conftest.$ac_ext <<EOF
  914. #line 915 "configure"
  915. #include "confdefs.h"
  916.  
  917. int main() { return 0; }
  918. int t() {
  919.  unsigned char un_char; 
  920. ; return 0; }
  921. EOF
  922. if eval $ac_compile; then
  923.   rm -rf conftest*
  924.   echo "$ac_t""yes" 1>&6
  925. cat >> confdefs.h <<\EOF
  926. #define HAVE_UNSIGNED_CHAR 
  927. EOF
  928.  
  929. else
  930.   rm -rf conftest*
  931.   echo "$ac_t""no" 1>&6
  932. fi
  933. rm -f conftest*
  934. echo $ac_n "checking for type unsigned short""... $ac_c" 1>&6
  935. cat > conftest.$ac_ext <<EOF
  936. #line 937 "configure"
  937. #include "confdefs.h"
  938.  
  939. int main() { return 0; }
  940. int t() {
  941.  unsigned short un_short; 
  942. ; return 0; }
  943. EOF
  944. if eval $ac_compile; then
  945.   rm -rf conftest*
  946.   echo "$ac_t""yes" 1>&6
  947. cat >> confdefs.h <<\EOF
  948. #define HAVE_UNSIGNED_SHORT 
  949. EOF
  950.  
  951. else
  952.   rm -rf conftest*
  953.   echo "$ac_t""no" 1>&6
  954. fi
  955. rm -f conftest*
  956. echo $ac_n "checking for type void""... $ac_c" 1>&6
  957. cat > conftest.$ac_ext <<EOF
  958. #line 959 "configure"
  959. #include "confdefs.h"
  960.  
  961. /* Caution: a C++ compiler will insist on valid prototypes */
  962. typedef void * void_ptr;    /* check void * */
  963. #ifdef HAVE_PROTOTYPES        /* check ptr to function returning void */
  964. typedef void (*void_func) (int a, int b);
  965. #else
  966. typedef void (*void_func) ();
  967. #endif
  968.  
  969. #ifdef HAVE_PROTOTYPES        /* check void function result */
  970. void test3function (void_ptr arg1, void_func arg2)
  971. #else
  972. void test3function (arg1, arg2)
  973.      void_ptr arg1;
  974.      void_func arg2;
  975. #endif
  976. {
  977.   char * locptr = (char *) arg1; /* check casting to and from void * */
  978.   arg1 = (void *) locptr;
  979.   (*arg2) (1, 2);        /* check call of fcn returning void */
  980. }
  981.  
  982. int main() { return 0; }
  983. int t() {
  984.  
  985. ; return 0; }
  986. EOF
  987. if eval $ac_compile; then
  988.   rm -rf conftest*
  989.   echo "$ac_t""yes" 1>&6
  990. else
  991.   rm -rf conftest*
  992.   echo "$ac_t""no" 1>&6
  993. cat >> confdefs.h <<\EOF
  994. #define void char
  995. EOF
  996.  
  997. fi
  998. rm -f conftest*
  999. echo $ac_n "checking for working const""... $ac_c" 1>&6
  1000. if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
  1001.   echo $ac_n "(cached) $ac_c" 1>&6
  1002. else
  1003.   cat > conftest.$ac_ext <<EOF
  1004. #line 1005 "configure"
  1005. #include "confdefs.h"
  1006.  
  1007. int main() { return 0; }
  1008. int t() {
  1009.  
  1010. /* Ultrix mips cc rejects this.  */
  1011. typedef int charset[2]; const charset x;
  1012. /* SunOS 4.1.1 cc rejects this.  */
  1013. char const *const *ccp;
  1014. char **p;
  1015. /* NEC SVR4.0.2 mips cc rejects this.  */
  1016. struct point {int x, y;};
  1017. static struct point const zero = {0,0};
  1018. /* AIX XL C 1.02.0.0 rejects this.
  1019.    It does not let you subtract one const X* pointer from another in an arm
  1020.    of an if-expression whose if-part is not a constant expression */
  1021. const char *g = "string";
  1022. ccp = &g + (g ? g-g : 0);
  1023. /* HPUX 7.0 cc rejects these. */
  1024. ++ccp;
  1025. p = (char**) ccp;
  1026. ccp = (char const *const *) p;
  1027. { /* SCO 3.2v4 cc rejects this.  */
  1028.   char *t;
  1029.   char const *s = 0 ? (char *) 0 : (char const *) 0;
  1030.  
  1031.   *t++ = 0;
  1032. }
  1033. { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
  1034.   int x[] = {25, 17};
  1035.   const int *foo = &x[0];
  1036.   ++foo;
  1037. }
  1038. { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
  1039.   typedef const int *iptr;
  1040.   iptr p = 0;
  1041.   ++p;
  1042. }
  1043. { /* AIX XL C 1.02.0.0 rejects this saying
  1044.      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
  1045.   struct s { int j; const int *ap[3]; };
  1046.   struct s *b; b->j = 5;
  1047. }
  1048. { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
  1049.   const int foo = 10;
  1050. }
  1051.  
  1052. ; return 0; }
  1053. EOF
  1054. if eval $ac_compile; then
  1055.   rm -rf conftest*
  1056.   ac_cv_c_const=yes
  1057. else
  1058.   rm -rf conftest*
  1059.   ac_cv_c_const=no
  1060. fi
  1061. rm -f conftest*
  1062.  
  1063. fi
  1064.  
  1065. echo "$ac_t""$ac_cv_c_const" 1>&6
  1066. if test $ac_cv_c_const = no; then
  1067.   cat >> confdefs.h <<\EOF
  1068. #define const 
  1069. EOF
  1070.  
  1071. fi
  1072.  
  1073. echo $ac_n "checking for inline""... $ac_c" 1>&6
  1074. ijg_cv_inline=""
  1075. cat > conftest.$ac_ext <<EOF
  1076. #line 1077 "configure"
  1077. #include "confdefs.h"
  1078.  
  1079. int main() { return 0; }
  1080. int t() {
  1081. } inline int foo() { return 0; }
  1082. int bar() { return foo();
  1083. ; return 0; }
  1084. EOF
  1085. if eval $ac_compile; then
  1086.   rm -rf conftest*
  1087.   ijg_cv_inline="inline"
  1088. else
  1089.   rm -rf conftest*
  1090.   cat > conftest.$ac_ext <<EOF
  1091. #line 1092 "configure"
  1092. #include "confdefs.h"
  1093.  
  1094. int main() { return 0; }
  1095. int t() {
  1096. } __inline__ int foo() { return 0; }
  1097. int bar() { return foo();
  1098. ; return 0; }
  1099. EOF
  1100. if eval $ac_compile; then
  1101.   rm -rf conftest*
  1102.   ijg_cv_inline="__inline__"
  1103. else
  1104.   rm -rf conftest*
  1105.   cat > conftest.$ac_ext <<EOF
  1106. #line 1107 "configure"
  1107. #include "confdefs.h"
  1108.  
  1109. int main() { return 0; }
  1110. int t() {
  1111. } __inline int foo() { return 0; }
  1112. int bar() { return foo();
  1113. ; return 0; }
  1114. EOF
  1115. if eval $ac_compile; then
  1116.   rm -rf conftest*
  1117.   ijg_cv_inline="__inline"
  1118. fi
  1119. rm -f conftest*
  1120.  
  1121. fi
  1122. rm -f conftest*
  1123.  
  1124. fi
  1125. rm -f conftest*
  1126. echo "$ac_t""$ijg_cv_inline" 1>&6
  1127. cat >> confdefs.h <<EOF
  1128. #define INLINE $ijg_cv_inline
  1129. EOF
  1130. echo $ac_n "checking for broken incomplete types""... $ac_c" 1>&6
  1131. cat > conftest.$ac_ext <<EOF
  1132. #line 1133 "configure"
  1133. #include "confdefs.h"
  1134.  typedef struct undefined_structure * undef_struct_ptr; 
  1135. int main() { return 0; }
  1136. int t() {
  1137.  
  1138. ; return 0; }
  1139. EOF
  1140. if eval $ac_compile; then
  1141.   rm -rf conftest*
  1142.   echo "$ac_t""ok" 1>&6
  1143. else
  1144.   rm -rf conftest*
  1145.   echo "$ac_t""broken" 1>&6
  1146. cat >> confdefs.h <<\EOF
  1147. #define INCOMPLETE_TYPES_BROKEN 
  1148. EOF
  1149.  
  1150. fi
  1151. rm -f conftest*
  1152. echo $ac_n "checking for short external names""... $ac_c" 1>&6
  1153. cat > conftest.$ac_ext <<EOF
  1154. #line 1155 "configure"
  1155. #include "confdefs.h"
  1156.  
  1157. int possibly_duplicate_function () { return 0; }
  1158. int possibly_dupli_function () { return 1; }
  1159.  
  1160. int main() { return 0; }
  1161. int t() {
  1162.  
  1163. ; return 0; }
  1164. EOF
  1165. if eval $ac_link; then
  1166.   rm -rf conftest*
  1167.   echo "$ac_t""ok" 1>&6
  1168. else
  1169.   rm -rf conftest*
  1170.   echo "$ac_t""short" 1>&6
  1171. cat >> confdefs.h <<\EOF
  1172. #define NEED_SHORT_EXTERNAL_NAMES 
  1173. EOF
  1174.  
  1175. fi
  1176. rm -f conftest*
  1177.  
  1178. echo $ac_n "checking to see if char is signed""... $ac_c" 1>&6
  1179. if test "$cross_compiling" = yes; then
  1180.   echo Assuming that char is signed on target machine.
  1181. echo If it is unsigned, this will be a little bit inefficient.
  1182.  
  1183. else
  1184. cat > conftest.$ac_ext <<EOF
  1185. #line 1186 "configure"
  1186. #include "confdefs.h"
  1187.  
  1188. #ifdef HAVE_PROTOTYPES
  1189. int is_char_signed (int arg)
  1190. #else
  1191. int is_char_signed (arg)
  1192.      int arg;
  1193. #endif
  1194. {
  1195.   if (arg == 189) {        /* expected result for unsigned char */
  1196.     return 0;            /* type char is unsigned */
  1197.   }
  1198.   else if (arg != -67) {    /* expected result for signed char */
  1199.     printf("Hmm, it seems 'char' is not eight bits wide on your machine.\n");
  1200.     printf("I fear the JPEG software will not work at all.\n\n");
  1201.   }
  1202.   return 1;            /* assume char is signed otherwise */
  1203. }
  1204. char signed_char_check = (char) (-67);
  1205. main() {
  1206.   exit(is_char_signed((int) signed_char_check));
  1207. }
  1208. EOF
  1209. eval $ac_link
  1210. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1211.   echo "$ac_t""no" 1>&6
  1212. cat >> confdefs.h <<\EOF
  1213. #define CHAR_IS_UNSIGNED 
  1214. EOF
  1215.  
  1216. else
  1217.   echo "$ac_t""yes" 1>&6
  1218. fi
  1219. fi
  1220. rm -fr conftest*
  1221. echo $ac_n "checking to see if right shift is signed""... $ac_c" 1>&6
  1222. if test "$cross_compiling" = yes; then
  1223.   echo "$ac_t""Assuming that right shift is signed on target machine." 1>&6
  1224. else
  1225. cat > conftest.$ac_ext <<EOF
  1226. #line 1227 "configure"
  1227. #include "confdefs.h"
  1228.  
  1229. #ifdef HAVE_PROTOTYPES
  1230. int is_shifting_signed (long arg)
  1231. #else
  1232. int is_shifting_signed (arg)
  1233.      long arg;
  1234. #endif
  1235. /* See whether right-shift on a long is signed or not. */
  1236. {
  1237.   long res = arg >> 4;
  1238.  
  1239.   if (res == -0x7F7E80CL) {    /* expected result for signed shift */
  1240.     return 1;            /* right shift is signed */
  1241.   }
  1242.   /* see if unsigned-shift hack will fix it. */
  1243.   /* we can't just test exact value since it depends on width of long... */
  1244.   res |= (~0L) << (32-4);
  1245.   if (res == -0x7F7E80CL) {    /* expected result now? */
  1246.     return 0;            /* right shift is unsigned */
  1247.   }
  1248.   printf("Right shift isn't acting as I expect it to.\n");
  1249.   printf("I fear the JPEG software will not work at all.\n\n");
  1250.   return 0;            /* try it with unsigned anyway */
  1251. }
  1252. main() {
  1253.   exit(is_shifting_signed(-0x7F7E80B1L));
  1254. }
  1255. EOF
  1256. eval $ac_link
  1257. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1258.   echo "$ac_t""no" 1>&6
  1259. cat >> confdefs.h <<\EOF
  1260. #define RIGHT_SHIFT_IS_UNSIGNED 
  1261. EOF
  1262.  
  1263. else
  1264.   echo "$ac_t""yes" 1>&6
  1265. fi
  1266. fi
  1267. rm -fr conftest*
  1268. echo $ac_n "checking to see if fopen accepts b spec""... $ac_c" 1>&6
  1269. if test "$cross_compiling" = yes; then
  1270.   echo "$ac_t""Assuming that it does." 1>&6
  1271. else
  1272. cat > conftest.$ac_ext <<EOF
  1273. #line 1274 "configure"
  1274. #include "confdefs.h"
  1275.  
  1276. #include <stdio.h>
  1277. main() {
  1278.   if (fopen("conftestdata", "wb") != NULL)
  1279.     exit(0);
  1280.   exit(1);
  1281. }
  1282. EOF
  1283. eval $ac_link
  1284. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1285.   echo "$ac_t""yes" 1>&6
  1286. else
  1287.   echo "$ac_t""no" 1>&6
  1288. cat >> confdefs.h <<\EOF
  1289. #define DONT_USE_B_MODE 
  1290. EOF
  1291.  
  1292. fi
  1293. fi
  1294. rm -fr conftest*
  1295.  
  1296. # Find a good install program.  We prefer a C program (faster),
  1297. # so one script is as good as another.  But avoid the broken or
  1298. # incompatible versions:
  1299. # SysV /etc/install, /usr/sbin/install
  1300. # SunOS /usr/etc/install
  1301. # IRIX /sbin/install
  1302. # AIX /bin/install
  1303. # AFS /usr/afsws/bin/install, which mishandles nonexistent args
  1304. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  1305. # ./install, which can be erroneously created by make from ./install.sh.
  1306. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
  1307. if test -z "$INSTALL"; then
  1308. if eval "test \"`echo '$''{'ijg_cv_path_install'+set}'`\" = set"; then
  1309.   echo $ac_n "(cached) $ac_c" 1>&6
  1310. else
  1311.     IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  1312.   for ac_dir in $PATH; do
  1313.     # Account for people who put trailing slashes in PATH elements.
  1314.     case "$ac_dir/" in
  1315.     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
  1316.     *)
  1317.       # OSF1 and SCO ODT 3.0 have their own names for install.
  1318.       for ac_prog in ginstall installbsd scoinst install; do
  1319.         if test -f $ac_dir/$ac_prog; then
  1320.       if test $ac_prog = install &&
  1321.             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
  1322.         # AIX install.  It has an incompatible calling convention.
  1323.         # OSF/1 installbsd also uses dspmsg, but is usable.
  1324.         :
  1325.       else
  1326.         ijg_cv_path_install="$ac_dir/$ac_prog -c"
  1327.         break 2
  1328.       fi
  1329.     fi
  1330.       done
  1331.       ;;
  1332.     esac
  1333.   done
  1334.   IFS="$ac_save_ifs"
  1335.   # As a last resort, use cp
  1336.   test -z "$ijg_cv_path_install" && ijg_cv_path_install="cp"
  1337. fi
  1338.   INSTALL="$ijg_cv_path_install"
  1339. fi
  1340. echo "$ac_t""$INSTALL" 1>&6
  1341.  
  1342. # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
  1343. # It thinks the first close brace ends the variable substitution.
  1344. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  1345.  
  1346. if test -z "$INSTALL_DATA"; then
  1347.   if test "$INSTALL" = cp; then
  1348.     INSTALL_DATA='${INSTALL}'
  1349.   else
  1350.     INSTALL_DATA='${INSTALL} -m 644'
  1351.   fi
  1352. fi
  1353.  
  1354. # Extract the first word of "ranlib", so it can be a program name with args.
  1355. set dummy ranlib; ac_word=$2
  1356. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  1357. if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
  1358.   echo $ac_n "(cached) $ac_c" 1>&6
  1359. else
  1360.   if test -n "$RANLIB"; then
  1361.   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  1362. else
  1363.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  1364.   for ac_dir in $PATH; do
  1365.     test -z "$ac_dir" && ac_dir=.
  1366.     if test -f $ac_dir/$ac_word; then
  1367.       ac_cv_prog_RANLIB="ranlib"
  1368.       break
  1369.     fi
  1370.   done
  1371.   IFS="$ac_save_ifs"
  1372.   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
  1373. fi
  1374. fi
  1375. RANLIB="$ac_cv_prog_RANLIB"
  1376. if test -n "$RANLIB"; then
  1377.   echo "$ac_t""$RANLIB" 1>&6
  1378. else
  1379.   echo "$ac_t""no" 1>&6
  1380. fi
  1381.  
  1382. MEMORYMGR="jmemnobs.o"
  1383. MAXMEM="no"
  1384. # Check whether --enable-maxmem or --disable-maxmem was given.
  1385. if test "${enable_maxmem+set}" = set; then
  1386.   enableval="$enable_maxmem"
  1387.   MAXMEM="$enableval"
  1388. fi
  1389.  
  1390. # support --with-maxmem for backwards compatibility with IJG V5.
  1391. # Check whether --with-maxmem or --without-maxmem was given.
  1392. if test "${with_maxmem+set}" = set; then
  1393.   withval="$with_maxmem"
  1394.   MAXMEM="$withval"
  1395. fi
  1396.  
  1397. if test "x$MAXMEM" = xyes; then
  1398.   MAXMEM=1
  1399. fi
  1400. if test "x$MAXMEM" != xno; then
  1401.   if test -n "`echo $MAXMEM | sed 's/[0-9]//g'`"; then
  1402.     { echo "configure: error: non-numeric argument to --enable-maxmem" 1>&2; exit 1; }
  1403.   fi
  1404.   DEFAULTMAXMEM=`expr $MAXMEM \* 1048576`
  1405. cat >> confdefs.h <<EOF
  1406. #define DEFAULT_MAX_MEM ${DEFAULTMAXMEM}
  1407. EOF
  1408.  
  1409. echo $ac_n "checking for 'tmpfile()'""... $ac_c" 1>&6
  1410. cat > conftest.$ac_ext <<EOF
  1411. #line 1412 "configure"
  1412. #include "confdefs.h"
  1413. #include <stdio.h>
  1414. int main() { return 0; }
  1415. int t() {
  1416.  FILE * tfile = tmpfile(); 
  1417. ; return 0; }
  1418. EOF
  1419. if eval $ac_link; then
  1420.   rm -rf conftest*
  1421.   echo "$ac_t""yes" 1>&6
  1422. MEMORYMGR="jmemansi.o"
  1423. else
  1424.   rm -rf conftest*
  1425.   echo "$ac_t""no" 1>&6
  1426. MEMORYMGR="jmemname.o"
  1427. cat >> confdefs.h <<\EOF
  1428. #define NEED_SIGNAL_CATCHER 
  1429. EOF
  1430. echo $ac_n "checking for 'mktemp()'""... $ac_c" 1>&6
  1431. cat > conftest.$ac_ext <<EOF
  1432. #line 1433 "configure"
  1433. #include "confdefs.h"
  1434.  
  1435. int main() { return 0; }
  1436. int t() {
  1437.  char fname[80]; mktemp(fname); 
  1438. ; return 0; }
  1439. EOF
  1440. if eval $ac_link; then
  1441.   rm -rf conftest*
  1442.   echo "$ac_t""yes" 1>&6
  1443. else
  1444.   rm -rf conftest*
  1445.   echo "$ac_t""no" 1>&6
  1446. cat >> confdefs.h <<\EOF
  1447. #define NO_MKTEMP 
  1448. EOF
  1449.  
  1450. fi
  1451. rm -f conftest*
  1452.  
  1453. fi
  1454. rm -f conftest*
  1455.  
  1456. fi
  1457.  
  1458. # Prepare to massage makefile.cfg correctly.
  1459. if test $ijg_cv_have_prototypes = yes; then
  1460.   ANSI2KNR=""
  1461.   ISANSICOM="# "
  1462. else
  1463.   ANSI2KNR="ansi2knr"
  1464.   ISANSICOM=""
  1465. fi
  1466. # ansi2knr needs -DBSD if string.h is missing
  1467. if test $ac_cv_header_string_h = no; then
  1468.   ANSI2KNRFLAGS="-DBSD"
  1469. else
  1470.   ANSI2KNRFLAGS=""
  1471. fi
  1472. # Set up -I directives
  1473. if test "x$srcdir" = x.; then
  1474.   INCLUDEFLAGS='-I$(srcdir)'
  1475. else
  1476.   INCLUDEFLAGS='-I. -I$(srcdir)'
  1477. fi
  1478. trap '' 1 2 15
  1479.  
  1480. trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
  1481.  
  1482. test "x$prefix" = xNONE && prefix=$ac_default_prefix
  1483. # Let make expand exec_prefix.
  1484. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
  1485.  
  1486. # Any assignment to VPATH causes Sun make to only execute
  1487. # the first set of double-colon rules, so remove it if not needed.
  1488. # If there is a colon in the path, we need to keep it.
  1489. if test "x$srcdir" = x.; then
  1490.   ac_vpsub='/^[     ]*VPATH[     ]*=[^:]*$/d'
  1491. fi
  1492.  
  1493. trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
  1494.  
  1495. DEFS=-DHAVE_CONFIG_H
  1496.  
  1497. # Without the "./", some shells look in PATH for config.status.
  1498. : ${CONFIG_STATUS=./config.status}
  1499.  
  1500. echo creating $CONFIG_STATUS
  1501. rm -f $CONFIG_STATUS
  1502. cat > $CONFIG_STATUS <<EOF
  1503. #! /bin/sh
  1504. # Generated automatically by configure.
  1505. # Run this file to recreate the current configuration.
  1506. # This directory was configured as follows,
  1507. # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  1508. #
  1509. # $0 $ac_configure_args
  1510. #
  1511. # Compiler output produced by configure, useful for debugging
  1512. # configure, is in ./config.log if it exists.
  1513.  
  1514. ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
  1515. for ac_option
  1516. do
  1517.   case "\$ac_option" in
  1518.   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
  1519.     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
  1520.     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
  1521.   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
  1522.     echo "$CONFIG_STATUS generated by autoconf version 2.7"
  1523.     exit 0 ;;
  1524.   -help | --help | --hel | --he | --h)
  1525.     echo "\$ac_cs_usage"; exit 0 ;;
  1526.   *) echo "\$ac_cs_usage"; exit 1 ;;
  1527.   esac
  1528. done
  1529.  
  1530. ac_given_srcdir=$srcdir
  1531.  
  1532. trap 'rm -fr `echo "Makefile:makefile.cfg jconfig.h:jconfig.cfg" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
  1533. EOF
  1534. cat >> $CONFIG_STATUS <<EOF
  1535.  
  1536. # Protect against being on the right side of a sed subst in config.status.
  1537. sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
  1538.  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
  1539. $ac_vpsub
  1540. $extrasub
  1541. s%@CFLAGS@%$CFLAGS%g
  1542. s%@CPPFLAGS@%$CPPFLAGS%g
  1543. s%@CXXFLAGS@%$CXXFLAGS%g
  1544. s%@DEFS@%$DEFS%g
  1545. s%@LDFLAGS@%$LDFLAGS%g
  1546. s%@LIBS@%$LIBS%g
  1547. s%@exec_prefix@%$exec_prefix%g
  1548. s%@prefix@%$prefix%g
  1549. s%@program_transform_name@%$program_transform_name%g
  1550. s%@bindir@%$bindir%g
  1551. s%@sbindir@%$sbindir%g
  1552. s%@libexecdir@%$libexecdir%g
  1553. s%@datadir@%$datadir%g
  1554. s%@sysconfdir@%$sysconfdir%g
  1555. s%@sharedstatedir@%$sharedstatedir%g
  1556. s%@localstatedir@%$localstatedir%g
  1557. s%@libdir@%$libdir%g
  1558. s%@includedir@%$includedir%g
  1559. s%@oldincludedir@%$oldincludedir%g
  1560. s%@infodir@%$infodir%g
  1561. s%@mandir@%$mandir%g
  1562. s%@CC@%$CC%g
  1563. s%@CPP@%$CPP%g
  1564. s%@INSTALL@%$INSTALL%g
  1565. s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
  1566. s%@INSTALL_DATA@%$INSTALL_DATA%g
  1567. s%@RANLIB@%$RANLIB%g
  1568. s%@MEMORYMGR@%$MEMORYMGR%g
  1569. s%@ANSI2KNR@%$ANSI2KNR%g
  1570. s%@ISANSICOM@%$ISANSICOM%g
  1571. s%@ANSI2KNRFLAGS@%$ANSI2KNRFLAGS%g
  1572. s%@INCLUDEFLAGS@%$INCLUDEFLAGS%g
  1573.  
  1574. CEOF
  1575. EOF
  1576. cat >> $CONFIG_STATUS <<EOF
  1577.  
  1578. CONFIG_FILES=\${CONFIG_FILES-"Makefile:makefile.cfg"}
  1579. EOF
  1580. cat >> $CONFIG_STATUS <<\EOF
  1581. for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
  1582.   # Support "outfile[:infile]", defaulting infile="outfile.in".
  1583.   case "$ac_file" in
  1584.   *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
  1585.        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  1586.   *) ac_file_in="${ac_file}.in" ;;
  1587.   esac
  1588.  
  1589.   # Adjust relative srcdir, etc. for subdirectories.
  1590.  
  1591.   # Remove last slash and all that follows it.  Not all systems have dirname.
  1592.   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
  1593.   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
  1594.     # The file is in a subdirectory.
  1595.     test ! -d "$ac_dir" && mkdir "$ac_dir"
  1596.     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
  1597.     # A "../" for each directory in $ac_dir_suffix.
  1598.     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
  1599.   else
  1600.     ac_dir_suffix= ac_dots=
  1601.   fi
  1602.  
  1603.   case "$ac_given_srcdir" in
  1604.   .)  srcdir=.
  1605.       if test -z "$ac_dots"; then top_srcdir=.
  1606.       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
  1607.   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
  1608.   *) # Relative path.
  1609.     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
  1610.     top_srcdir="$ac_dots$ac_given_srcdir" ;;
  1611.   esac
  1612.  
  1613.   echo creating "$ac_file"
  1614.   rm -f "$ac_file"
  1615.   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
  1616.   case "$ac_file" in
  1617.   *Makefile*) ac_comsub="1i\\
  1618. # $configure_input" ;;
  1619.   *) ac_comsub= ;;
  1620.   esac
  1621.   sed -e "$ac_comsub
  1622. s%@configure_input@%$configure_input%g
  1623. s%@srcdir@%$srcdir%g
  1624. s%@top_srcdir@%$top_srcdir%g
  1625. " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
  1626. fi; done
  1627. rm -f conftest.subs
  1628.  
  1629. # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
  1630. # NAME is the cpp macro being defined and VALUE is the value it is being given.
  1631. #
  1632. # ac_d sets the value in "#define NAME VALUE" lines.
  1633. ac_dA='s%^\([     ]*\)#\([     ]*define[     ][     ]*\)'
  1634. ac_dB='\([     ][     ]*\)[^     ]*%\1#\2'
  1635. ac_dC='\3'
  1636. ac_dD='%g'
  1637. # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
  1638. ac_uA='s%^\([     ]*\)#\([     ]*\)undef\([     ][     ]*\)'
  1639. ac_uB='\([     ]\)%\1#\2define\3'
  1640. ac_uC=' '
  1641. ac_uD='\4%g'
  1642. # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
  1643. ac_eA='s%^\([     ]*\)#\([     ]*\)undef\([     ][     ]*\)'
  1644. ac_eB='$%\1#\2define\3'
  1645. ac_eC=' '
  1646. ac_eD='%g'
  1647.  
  1648. CONFIG_HEADERS=${CONFIG_HEADERS-"jconfig.h:jconfig.cfg"}
  1649. for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
  1650.   # Support "outfile[:infile]", defaulting infile="outfile.in".
  1651.   case "$ac_file" in
  1652.   *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
  1653.        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  1654.   *) ac_file_in="${ac_file}.in" ;;
  1655.   esac
  1656.  
  1657.   echo creating $ac_file
  1658.  
  1659.   rm -f conftest.frag conftest.in conftest.out
  1660.   cp $ac_given_srcdir/$ac_file_in conftest.in
  1661.  
  1662. EOF
  1663.  
  1664. # Transform confdefs.h into a sed script conftest.vals that substitutes
  1665. # the proper values into config.h.in to produce config.h.  And first:
  1666. # Protect against being on the right side of a sed subst in config.status.
  1667. # Protect against being in an unquoted here document in config.status.
  1668. rm -f conftest.vals
  1669. cat > conftest.hdr <<\EOF
  1670. s/[\\&%]/\\&/g
  1671. s%[\\$`]%\\&%g
  1672. s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
  1673. s%ac_d%ac_u%gp
  1674. s%ac_u%ac_e%gp
  1675. EOF
  1676. sed -n -f conftest.hdr confdefs.h > conftest.vals
  1677. rm -f conftest.hdr
  1678.  
  1679. # This sed command replaces #undef with comments.  This is necessary, for
  1680. # example, in the case of _POSIX_SOURCE, which is predefined and required
  1681. # on some systems where configure will not decide to define it.
  1682. cat >> conftest.vals <<\EOF
  1683. EOF
  1684.  
  1685. # Break up conftest.vals because some shells have a limit on
  1686. # the size of here documents, and old seds have small limits too.
  1687. # Maximum number of lines to put in a single here document.
  1688. ac_max_here_lines=12
  1689.  
  1690. rm -f conftest.tail
  1691. while :
  1692. do
  1693.   ac_lines=`grep -c . conftest.vals`
  1694.   # grep -c gives empty output for an empty file on some AIX systems.
  1695.   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
  1696.   # Write a limited-size here document to conftest.frag.
  1697.   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
  1698.   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
  1699.   echo 'CEOF
  1700.   sed -f conftest.frag conftest.in > conftest.out
  1701.   rm -f conftest.in
  1702.   mv conftest.out conftest.in
  1703. ' >> $CONFIG_STATUS
  1704.   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
  1705.   rm -f conftest.vals
  1706.   mv conftest.tail conftest.vals
  1707. done
  1708. rm -f conftest.vals
  1709.  
  1710. cat >> $CONFIG_STATUS <<\EOF
  1711.   rm -f conftest.frag conftest.h
  1712.   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
  1713.   cat conftest.in >> conftest.h
  1714.   rm -f conftest.in
  1715.   if cmp -s $ac_file conftest.h 2>/dev/null; then
  1716.     echo "$ac_file is unchanged"
  1717.     rm -f conftest.h
  1718.   else
  1719.     rm -f $ac_file
  1720.     mv conftest.h $ac_file
  1721.   fi
  1722. fi; done
  1723.  
  1724.  
  1725.  
  1726. exit 0
  1727. EOF
  1728. chmod +x $CONFIG_STATUS
  1729. rm -fr confdefs* $ac_clean_files
  1730. test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
  1731.  
  1732.